3.8 \(\int \tan ^8(c+d x) \, dx\)

Optimal. Leaf size=58 \[ \frac {\tan ^7(c+d x)}{7 d}-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^3(c+d x)}{3 d}-\frac {\tan (c+d x)}{d}+x \]

[Out]

x-tan(d*x+c)/d+1/3*tan(d*x+c)^3/d-1/5*tan(d*x+c)^5/d+1/7*tan(d*x+c)^7/d

________________________________________________________________________________________

Rubi [A]  time = 0.03, antiderivative size = 58, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 2, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.250, Rules used = {3473, 8} \[ \frac {\tan ^7(c+d x)}{7 d}-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^3(c+d x)}{3 d}-\frac {\tan (c+d x)}{d}+x \]

Antiderivative was successfully verified.

[In]

Int[Tan[c + d*x]^8,x]

[Out]

x - Tan[c + d*x]/d + Tan[c + d*x]^3/(3*d) - Tan[c + d*x]^5/(5*d) + Tan[c + d*x]^7/(7*d)

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 3473

Int[((b_.)*tan[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*(b*Tan[c + d*x])^(n - 1))/(d*(n - 1)), x] - Dis
t[b^2, Int[(b*Tan[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1]

Rubi steps

\begin {align*} \int \tan ^8(c+d x) \, dx &=\frac {\tan ^7(c+d x)}{7 d}-\int \tan ^6(c+d x) \, dx\\ &=-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^7(c+d x)}{7 d}+\int \tan ^4(c+d x) \, dx\\ &=\frac {\tan ^3(c+d x)}{3 d}-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^7(c+d x)}{7 d}-\int \tan ^2(c+d x) \, dx\\ &=-\frac {\tan (c+d x)}{d}+\frac {\tan ^3(c+d x)}{3 d}-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^7(c+d x)}{7 d}+\int 1 \, dx\\ &=x-\frac {\tan (c+d x)}{d}+\frac {\tan ^3(c+d x)}{3 d}-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^7(c+d x)}{7 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 68, normalized size = 1.17 \[ \frac {\tan ^{-1}(\tan (c+d x))}{d}+\frac {\tan ^7(c+d x)}{7 d}-\frac {\tan ^5(c+d x)}{5 d}+\frac {\tan ^3(c+d x)}{3 d}-\frac {\tan (c+d x)}{d} \]

Antiderivative was successfully verified.

[In]

Integrate[Tan[c + d*x]^8,x]

[Out]

ArcTan[Tan[c + d*x]]/d - Tan[c + d*x]/d + Tan[c + d*x]^3/(3*d) - Tan[c + d*x]^5/(5*d) + Tan[c + d*x]^7/(7*d)

________________________________________________________________________________________

fricas [A]  time = 0.62, size = 48, normalized size = 0.83 \[ \frac {15 \, \tan \left (d x + c\right )^{7} - 21 \, \tan \left (d x + c\right )^{5} + 35 \, \tan \left (d x + c\right )^{3} + 105 \, d x - 105 \, \tan \left (d x + c\right )}{105 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*x+c)^8,x, algorithm="fricas")

[Out]

1/105*(15*tan(d*x + c)^7 - 21*tan(d*x + c)^5 + 35*tan(d*x + c)^3 + 105*d*x - 105*tan(d*x + c))/d

________________________________________________________________________________________

giac [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: NotImplementedError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*x+c)^8,x, algorithm="giac")

[Out]

Exception raised: NotImplementedError >> Unable to parse Giac output: Unable to check sign: (2*pi/x/2)>(-2*pi/
x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check si
gn: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/
x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check si
gn: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/
x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check si
gn: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/x/2)Unable to check sign: (2*pi/x/2)>(-2*pi/
x/2)(420*d*x*tan(c)^7*tan(d*x)^7-2940*d*x*tan(c)^6*tan(d*x)^6+8820*d*x*tan(c)^5*tan(d*x)^5-14700*d*x*tan(c)^4*
tan(d*x)^4+14700*d*x*tan(c)^3*tan(d*x)^3-8820*d*x*tan(c)^2*tan(d*x)^2+2940*d*x*tan(c)*tan(d*x)-420*d*x-105*pi*
sign(2*tan(c)^2*tan(d*x)+2*tan(c)*tan(d*x)^2-2*tan(c)-2*tan(d*x))*tan(c)^7*tan(d*x)^7+735*pi*sign(2*tan(c)^2*t
an(d*x)+2*tan(c)*tan(d*x)^2-2*tan(c)-2*tan(d*x))*tan(c)^6*tan(d*x)^6-2205*pi*sign(2*tan(c)^2*tan(d*x)+2*tan(c)
*tan(d*x)^2-2*tan(c)-2*tan(d*x))*tan(c)^5*tan(d*x)^5+3675*pi*sign(2*tan(c)^2*tan(d*x)+2*tan(c)*tan(d*x)^2-2*ta
n(c)-2*tan(d*x))*tan(c)^4*tan(d*x)^4-3675*pi*sign(2*tan(c)^2*tan(d*x)+2*tan(c)*tan(d*x)^2-2*tan(c)-2*tan(d*x))
*tan(c)^3*tan(d*x)^3+2205*pi*sign(2*tan(c)^2*tan(d*x)+2*tan(c)*tan(d*x)^2-2*tan(c)-2*tan(d*x))*tan(c)^2*tan(d*
x)^2-735*pi*sign(2*tan(c)^2*tan(d*x)+2*tan(c)*tan(d*x)^2-2*tan(c)-2*tan(d*x))*tan(c)*tan(d*x)+105*pi*sign(2*ta
n(c)^2*tan(d*x)+2*tan(c)*tan(d*x)^2-2*tan(c)-2*tan(d*x))-105*pi*tan(c)^7*tan(d*x)^7+735*pi*tan(c)^6*tan(d*x)^6
-2205*pi*tan(c)^5*tan(d*x)^5+3675*pi*tan(c)^4*tan(d*x)^4-3675*pi*tan(c)^3*tan(d*x)^3+2205*pi*tan(c)^2*tan(d*x)
^2-735*pi*tan(c)*tan(d*x)+105*pi+210*atan((tan(c)*tan(d*x)-1)/(tan(c)+tan(d*x)))*tan(c)^7*tan(d*x)^7-1470*atan
((tan(c)*tan(d*x)-1)/(tan(c)+tan(d*x)))*tan(c)^6*tan(d*x)^6+4410*atan((tan(c)*tan(d*x)-1)/(tan(c)+tan(d*x)))*t
an(c)^5*tan(d*x)^5-7350*atan((tan(c)*tan(d*x)-1)/(tan(c)+tan(d*x)))*tan(c)^4*tan(d*x)^4+7350*atan((tan(c)*tan(
d*x)-1)/(tan(c)+tan(d*x)))*tan(c)^3*tan(d*x)^3-4410*atan((tan(c)*tan(d*x)-1)/(tan(c)+tan(d*x)))*tan(c)^2*tan(d
*x)^2+1470*atan((tan(c)*tan(d*x)-1)/(tan(c)+tan(d*x)))*tan(c)*tan(d*x)-210*atan((tan(c)*tan(d*x)-1)/(tan(c)+ta
n(d*x)))+210*atan((tan(c)+tan(d*x))/(tan(c)*tan(d*x)-1))*tan(c)^7*tan(d*x)^7-1470*atan((tan(c)+tan(d*x))/(tan(
c)*tan(d*x)-1))*tan(c)^6*tan(d*x)^6+4410*atan((tan(c)+tan(d*x))/(tan(c)*tan(d*x)-1))*tan(c)^5*tan(d*x)^5-7350*
atan((tan(c)+tan(d*x))/(tan(c)*tan(d*x)-1))*tan(c)^4*tan(d*x)^4+7350*atan((tan(c)+tan(d*x))/(tan(c)*tan(d*x)-1
))*tan(c)^3*tan(d*x)^3-4410*atan((tan(c)+tan(d*x))/(tan(c)*tan(d*x)-1))*tan(c)^2*tan(d*x)^2+1470*atan((tan(c)+
tan(d*x))/(tan(c)*tan(d*x)-1))*tan(c)*tan(d*x)-210*atan((tan(c)+tan(d*x))/(tan(c)*tan(d*x)-1))+420*tan(c)^7*ta
n(d*x)^6-140*tan(c)^7*tan(d*x)^4+84*tan(c)^7*tan(d*x)^2-60*tan(c)^7+420*tan(c)^6*tan(d*x)^7-2940*tan(c)^6*tan(
d*x)^5+980*tan(c)^6*tan(d*x)^3-588*tan(c)^6*tan(d*x)-2940*tan(c)^5*tan(d*x)^6+8820*tan(c)^5*tan(d*x)^4-2940*ta
n(c)^5*tan(d*x)^2+84*tan(c)^5-140*tan(c)^4*tan(d*x)^7+8820*tan(c)^4*tan(d*x)^5-14700*tan(c)^4*tan(d*x)^3+980*t
an(c)^4*tan(d*x)+980*tan(c)^3*tan(d*x)^6-14700*tan(c)^3*tan(d*x)^4+8820*tan(c)^3*tan(d*x)^2-140*tan(c)^3+84*ta
n(c)^2*tan(d*x)^7-2940*tan(c)^2*tan(d*x)^5+8820*tan(c)^2*tan(d*x)^3-2940*tan(c)^2*tan(d*x)-588*tan(c)*tan(d*x)
^6+980*tan(c)*tan(d*x)^4-2940*tan(c)*tan(d*x)^2+420*tan(c)-60*tan(d*x)^7+84*tan(d*x)^5-140*tan(d*x)^3+420*tan(
d*x))/(420*d*tan(c)^7*tan(d*x)^7-2940*d*tan(c)^6*tan(d*x)^6+8820*d*tan(c)^5*tan(d*x)^5-14700*d*tan(c)^4*tan(d*
x)^4+14700*d*tan(c)^3*tan(d*x)^3-8820*d*tan(c)^2*tan(d*x)^2+2940*d*tan(c)*tan(d*x)-420*d)

________________________________________________________________________________________

maple [A]  time = 0.01, size = 61, normalized size = 1.05 \[ \frac {\tan ^{7}\left (d x +c \right )}{7 d}-\frac {\tan ^{5}\left (d x +c \right )}{5 d}+\frac {\tan ^{3}\left (d x +c \right )}{3 d}-\frac {\tan \left (d x +c \right )}{d}+\frac {d x +c}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(d*x+c)^8,x)

[Out]

1/7*tan(d*x+c)^7/d-1/5*tan(d*x+c)^5/d+1/3*tan(d*x+c)^3/d-tan(d*x+c)/d+1/d*(d*x+c)

________________________________________________________________________________________

maxima [A]  time = 0.63, size = 51, normalized size = 0.88 \[ \frac {15 \, \tan \left (d x + c\right )^{7} - 21 \, \tan \left (d x + c\right )^{5} + 35 \, \tan \left (d x + c\right )^{3} + 105 \, d x + 105 \, c - 105 \, \tan \left (d x + c\right )}{105 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*x+c)^8,x, algorithm="maxima")

[Out]

1/105*(15*tan(d*x + c)^7 - 21*tan(d*x + c)^5 + 35*tan(d*x + c)^3 + 105*d*x + 105*c - 105*tan(d*x + c))/d

________________________________________________________________________________________

mupad [B]  time = 2.52, size = 44, normalized size = 0.76 \[ x-\frac {-\frac {{\mathrm {tan}\left (c+d\,x\right )}^7}{7}+\frac {{\mathrm {tan}\left (c+d\,x\right )}^5}{5}-\frac {{\mathrm {tan}\left (c+d\,x\right )}^3}{3}+\mathrm {tan}\left (c+d\,x\right )}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(c + d*x)^8,x)

[Out]

x - (tan(c + d*x) - tan(c + d*x)^3/3 + tan(c + d*x)^5/5 - tan(c + d*x)^7/7)/d

________________________________________________________________________________________

sympy [A]  time = 0.92, size = 51, normalized size = 0.88 \[ \begin {cases} x + \frac {\tan ^{7}{\left (c + d x \right )}}{7 d} - \frac {\tan ^{5}{\left (c + d x \right )}}{5 d} + \frac {\tan ^{3}{\left (c + d x \right )}}{3 d} - \frac {\tan {\left (c + d x \right )}}{d} & \text {for}\: d \neq 0 \\x \tan ^{8}{\relax (c )} & \text {otherwise} \end {cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(d*x+c)**8,x)

[Out]

Piecewise((x + tan(c + d*x)**7/(7*d) - tan(c + d*x)**5/(5*d) + tan(c + d*x)**3/(3*d) - tan(c + d*x)/d, Ne(d, 0
)), (x*tan(c)**8, True))

________________________________________________________________________________________